<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    
  <script>
        window.onscroll = throttle(function() {
        $('#parent').append(
            <div></div>
            <div></div>
            <div></div>
            <div></div>
            <div></div>
        )
    }, 1000)
        
       



    function throttle(func, delay) {
        
        var timer = null
        return function () {
            //判断timer是否存在，不存在则创建
            if (!timer) {
            timer = setTimeout(function () {
                func()
                //执行完成后清除
                timer = null
            }, delay)
            }
        }
    }


  </script>
</body>
</html>